<div class="formulario" id="formularioDados<?=(isset($linha[0])) ? $linha[0] : '0'?>">
	<form onSubmit="return Usuario.validaCampos(<?=(isset($linha[0])) ? $linha[0] : '0'?>);" action="<?=site_url('admin/administradores/salvar' . (isset($linha[0]) ? '/' . $linha[0] : ''))?>" method="POST">
		<?php if(isset($linha)):?>
			<input type="hidden" value="<?=$linha[0]?>" name="id" />
		<?php endif;?>
		<table class="tabelaForm">
			<tr align="right">
				<td>Nome: <input class="inputForm validar<?=(isset($linha[0])) ? $linha[0] : '0'?>" type="text" value="<?=(isset($linha)) ? $linha[1] : '';?>" name="nome" human="Nome" /></td>
				<td>Email: <input class="inputForm validar<?=(isset($linha[0])) ? $linha[0] : '0'?>" type="text" value="<?=(isset($linha)) ? $linha[3] : '';?>" name="email" human="E-mail" /></td>
			</tr>
			<tr align="right">
				<td>Senha: <input class="inputForm<?=(isset($linha[0])) ? '' : ' validar0'?>" type="password" value="" name="senha" human="Senha" /></td>
				<td>Confirmação de Senha: <input class="inputForm<?=(isset($linha[0])) ? '' : ' validar0'?>" type="password" value="" name="confsenha" human="Confirmação de Senha" /></td>
			</tr>
			<tr align="right">
				<td colspan="2">Grupo: 
					<select class="inputForm" name="grupo">
						<?php 
							$grupos = new Grupo();
							foreach($grupos->get()->all as $g):
						?>
								<option value="<?=$g->id?>" <?=(isset($linha) && $g->id == $linha[4]) ? ' selected=selected' : ''?>><?=$g->nome?></option>
						<?php endforeach;?>
					</select>
				</td>
			</tr>
			<tr><td colspan="2" align="center"><input type="submit" class="bt" value="Salvar" style="width: auto; margin-top: 20px;" /></td></tr>
		</table>
	</form>
</div>